package de.codi.xtest;

import de.codi.CODISettings;
import eu.sealsproject.platform.repos.tdrs.client.TestCaseIterator;
import eu.sealsproject.platform.repos.tdrs.client.TestDataSuite;

/**
* 
* Shows how to use the SEALS TDRS (test data respository service)
* Can be used for running experiments on full sets of alignments.
*
*/
public class SealsTDRSExample {

	public static void main(String[] args) {
		
		
//		String testCollectionName    = "Anatomy Testsuite";
//		String testCollectionVersion = "2010";	
		
//	    String testCollectionName    = "Benchmark Testsuite";
//		String testCollectionVersion = "2010full";

        // benchmark 2:
        // String testCollectionName = "b50cbebb-5be3-4fc6-a02d-3a801791770c";
        // String testCollectionVersion = "ebee3a34-a155-4d50-879f-33372822db4d";
        // CODISettings.SEALS_TDRS_URL = "http://seals-test.sti2.at/tdrs-web/";

        // benchmark 3:
        String testCollectionName = "81a7f2d2-81fd-4a6d-b076-3adc7b3e0918";
        String testCollectionVersion = "8372414c-0185-4ff0-921b-969620c04777";
        CODISettings.SEALS_TDRS_URL = "http://seals-test.sti2.at/tdrs-web/";
	    
//	    String testCollectionName = "Conference Testsuite";
//		String testCollectionVersion = "2010";
		
		TestDataSuite tds = new TestDataSuite(CODISettings.SEALS_TDRS_URL, testCollectionName, testCollectionVersion);
		TestCaseIterator it = tds.getTestCases();
	
		while (it.hasNext()) {
			String testCaseId = it.next();
			System.out.println("testcase with id: "+ testCaseId);
			System.out.println("\tcomponent source:    " + tds.getDataItem(testCaseId, "source"));
			System.out.println("\tcomponent target:    " + tds.getDataItem(testCaseId, "target"));
			System.out.println("\tcomponent reference: " + tds.getDataItem(testCaseId, "reference"));
		}
		
	}

}
